package com.showsu.editor.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.showsu.editor.entity.po.TblRemoteInterfaceWarnSmsRecord;

/**
 * @Author: William
 * @Description:
 * @Date: Created in 8:00 下午 2024/1/24
 * @Modified By:
 */
public interface IRemoteInterfaceWarnSmsRecordService extends IService<TblRemoteInterfaceWarnSmsRecord> {

    /**
     * 新增记录
     * @param interfaceId 接口id
     */
    void addRecord(Long interfaceId);

    /**
     * 如果某接口在15分钟内未告警过，则发送告警短信；如果告警过，则不发送。同时启动接口自动切换逻辑。
     * @param interfaceId 接口id
     * @param params 记录参数信息，传递格式：key=value,key=value,.....
     * @return
     */
    void sendWarnSmsIn15mins(Long interfaceId, String params);
}
